<?php
namespace pinduoduo\Request;

use pinduoduo\AbstractInterface\Request;

class PddDdkOauthCmsPromUrlGenerateRequest extends Request
{

    /**
     * 生成商城推广链接接口
     * @var string
     */
    private $type = 'pdd.ddk.oauth.cms.prom.url.generate';

    /**
     * 0, "1.9包邮"；1, "今日爆款"； 2, "品牌清仓"； 4,"PC端专属商城"；不传值为默认商城
     * @var
     */
    private $channelType;

    /**
     * 自定义参数，为链接打上自定义标签；自定义参数最长限制64个字节；格式为： {"uid":"11111","sid":"22222"} ，其中 uid 用户唯一标识，可自行加密后传入，每个用户仅且对应一个标识，必填； sid 上下文信息标识，例如sessionId等，非必填。该json字符串中也可以加入其他自定义的key。（如果使用GET请求，请使用URLEncode处理参数）
     * @var
     */
    private $customParameters;

    /**
     * 是否生成手机跳转链接。true-是，false-否，默认false
     * @var
     */
    private $generateMobile;

    /**
     * 是否返回 schema URL
     * @var
     */
    private $generateSchemaUrl;

    /**
     * 是否生成短链接，true-是，false-否
     * @var
     */
    private $generateShortUrl;

    /**
     * 是否生成拼多多福利券微信小程序推广信息
     * @var
     */
    private $generateWeApp;

    /**
     * 搜索关键词
     * @var
     */
    private $keyword;

    /**
     * 单人团多人团标志。true-多人团，false-单人团 默认false
     * @var
     */
    private $multiGroup;

    /**
     * 推广位列表，例如：["60005_612"]
     * @var
     */
    private $pIdList;

    public function setType($type)
    {
        $this->type = $type;
    }

    public function getType()
    {
        return $this->type;
    }

    public function setChannelType($channelType)
    {
        $this->channelType = $channelType;
    }

    public function getChannelType()
    {
        return $this->channelType;
    }

    public function setCustomParameters($customParameters)
    {
        $this->customParameters = $customParameters;
    }

    public function getCustomParameters()
    {
        return $this->customParameters;
    }

    public function setGenerateMobile($generateMobile)
    {
        $this->generateMobile = $generateMobile;
    }

    public function getGenerateMobile()
    {
        return $this->generateMobile;
    }

    public function setGenerateSchemaUrl($generateSchemaUrl)
    {
        $this->generateSchemaUrl = $generateSchemaUrl;
    }

    public function getGenerateSchemaUrl()
    {
        return $this->generateSchemaUrl;
    }

    public function setGenerateShortUrl($generateShortUrl)
    {
        $this->generateShortUrl = $generateShortUrl;
    }

    public function getGenerateShortUrl()
    {
        return $this->generateShortUrl;
    }

    public function setGenerateWeApp($generateWeApp)
    {
        $this->generateWeApp = $generateWeApp;
    }

    public function getGenerateWeApp()
    {
        return $this->generateWeApp;
    }

    public function setKeyword($keyword)
    {
        $this->keyword = $keyword;
    }

    public function getKeyword()
    {
        return $this->keyword;
    }

    public function setMultiGroup($multiGroup)
    {
        $this->multiGroup = $multiGroup;
    }

    public function getMultiGroup()
    {
        return $this->multiGroup;
    }

    public function setPIdList($pIdList)
    {
        $this->pIdList = $pIdList;
    }

    public function getPIdList()
    {
        return $this->pIdList;
    }

    public function getParams()
    {
        $params = [
            'type'                => $this->type,
            'channel_type'        => $this->channelType,
            'custom_parameters'   => $this->customParameters,
            'generate_mobile'     => $this->generateMobile,
            'generate_schema_url' => $this->generateSchemaUrl,
            'generate_short_url'  => $this->generateShortUrl,
            'generate_we_app'     => $this->generateWeApp,
            'keyword'             => $this->keyword,
            'multi_group'         => $this->multiGroup,
            'p_id_list'           => $this->pIdList,
        ];
        return array_filter($params);
    }
}
